From: Øyvind Kolås Date: Thu, 30 May 2019 15:50:10 +0000 (+0200) Subject: babl: always intialize encoding pointer during format construction X-Git-Tag: archive/raspbian/1%0.1.106-3+rpi1^2~15^2~11^2~109 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=d1b1ba7ac66455c3de14b685d309620334d47b71;p=babl.git babl: always intialize encoding pointer during format construction This fixes issue #35, we initialize with NULL which will cause babl_format_get_encoding to itself call babl_get_name rather. --- diff --git a/babl/babl-format.c b/babl/babl-format.c index 5784196..accc15a 100644 --- a/babl/babl-format.c +++ b/babl/babl-format.c @@ -127,6 +127,7 @@ format_new (const char *name, babl->format.palette = 0; babl->format.space = (void*)space; + babl->format.encoding = NULL; return babl; }